package com.bigknow.appstore.web.console.controller;

import com.bigknow.appstore.web.console.service.IDBServiceService;
import com.bigknow.appstore.web.console.service.impl.DBServiceService;
import com.bigknow.fusion.common.model.appstore.DataService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

/**
 * Created by 李科风 on 2016-09-19.
 */
@Controller
@RequestMapping("/console/service")
public class DBServiceController {

    @Autowired
    private IDBServiceService service;

    @RequestMapping
    public String index() {
        return "/console/service/index";
    }

    @RequestMapping("/loginFusion")
    @ResponseBody
    public String loginFusion() {
        return service.loginFusion();
    }

    @RequestMapping("/getDataService")
    @ResponseBody
    public List<DataService> getDataService() {
        return service.getDataService();
    }
}
